<?php
	global  $_W,$_GPC;
	if($_W['role']){
		$name = $_GPC['categoryname'];
		$order = $_GPC['category_order'];
		$bg_color = $_GPC['bg_color'];
		$id = $_GPC['id'];
		$up = pdo_update('mii_ang_class',array('categoryname'=>$name,'category_order'=>$order,'bg_color'=>$bg_color),array('id'=>$id));
		if($up){
			$code = array('status'=>'1','msg'=>'保存成功');
			exit(json_encode($code));
		}else{
			$code = array('status'=>'2','msg'=>'保存失败');
			exit(json_encode($code));			
		}		
	}else{
		$code = json_encode(array('status'=>'2','msg'=>'没有操作权限'));
		exit($code);
	}


?>